<html>
<body>
<script type="text/javascript" src="http://localhost:8082/socket.io.js"></script>
<script> 
    var socket = new io.Socket(null,{port:8082,rememberTransport:true,timeout:1500});
 socket.connect();
socket.on('connect', function(){ console.log('connected to server'); socket.send('Hi Server...'); }) ;
socket.on('message', function(){ console.log('recieved a message!'); }) ;
socket.on('disconnect', function(){ console.log('disconnected from server'); }) ;
</script> 
</body>
</html>